extends Object

static func readStr(filePath: String) -> String:
	if !FileAccess.file_exists(filePath):
		return ""
	var file = FileAccess.open(filePath, FileAccess.READ)
	var content = file.get_as_text()
	file = null
	return content

static func readByteArr(filePath: String) -> PackedByteArray:
	if !FileAccess.file_exists(filePath):
		return PackedByteArray()
	var file = FileAccess.open(filePath, FileAccess.READ)
	var arr = file.get_buffer(file.get_length())
	file = null
	return arr

static func writeStr(filePath: String, content: String):
	var file = FileAccess.open(filePath, FileAccess.WRITE)
	file.store_string(content)
	file = null
